/***API***/
import * as baseAPI from "@/api";
import qs from "qs";
const request = baseAPI.request;

const API = {
  getList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetInStorage",
      data: obj
    };
    return request(requestData);
  },

  getGoodsTypeList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywckGetItems",
      data: obj
    };
    return request(requestData);
  },

  getCateNameList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetItemCate",
      data: obj
    };
    return request(requestData);
  },

  getInDetailsList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetInStorageDetail",
      data: obj
    };
    return request(requestData);
  },

  saveInventory: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKAddInStorage",
      data: obj
    };
    return request(requestData);
  },

  repeal: obj => {
    let requestData = {
      method: "post",
      url: "VCK/CancelInstorage",
      data: obj
    };
    return request(requestData);
  },

  delete(obj) {
    let requestData = {
      method: "post",
      url: "VCK/ywCKDelInStorage",
      data: obj
    };
    return request(requestData);
  },

  audit: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKConfirmInStorage",
      data: obj
    };
    return request(requestData);
  },

  getInTypeList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetInOutCate",
      data: obj
    };
    return request(requestData);
  },

  getDetailsList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetInStorageDetail",
      data: obj
    };
    return request(requestData);
  },

  getOutInStorage: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetConfirmedOrders",
      data: obj
    };
    return request(requestData);
  },

  getOutTypeList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetInOutCate",
      data: obj
    };
    return request(requestData);
  },

  getSupNameList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/GetAllYWCKSupplier",
      data: obj
    };
    return request(requestData);
  },

  getAllotGoodList: obj => {
    let requestData = {
      method: "post",
      url: "VCK/ywCKGetOutStorageDetail",
      data: obj
    };
    return request(requestData);
  }
};

export default API;
